package components;

import org.newdawn.slick.Image;
import org.newdawn.slick.SlickException;

/**
 * This class defines the attributes to all different fields. 
 * Every other field type extends from this class
 */
public class Field {

	/**
	 * The coordinates of this field
	 */
	public float[] position;

	/**
	 * Is true if field can be destroyed by a bomb
	 */
	public boolean destroy;

	/**
	 * Is true if field can be moved
	 */
	public boolean move;

	/**
	 * Is True if Player can walk over the field
	 */
	public boolean walk;

	/**
	 * Is the Image of this field
	 */
	public Image img;

	/**
	 * Specifies the Type of this field
	 */
	public String type;

	/**
	 * Defines the moving speed of this object in x direction 
	 */
	public float speedx;

	/**
	 * Defines the moving speed of this object in x direction 
	 */
	public float speedy;

	/**
	 * The hidden Item in this field. Can be null
	 */
	public transient Item item;

	/**
	 * Standard constructor
	 */
	public Field(float[] position, boolean destroy, boolean move,
			boolean walk, Image img, String type) {
		this.position = position;
		this.destroy = destroy;
		this.move = move;
		this.walk = walk;
		this.type=type;
		this.img=img;
	}

	/**
	 * Deletes the Field
	 */
	public void delete(){

	}

	/**
	 * Uses the own effect on the transmitted player
	 * @param bomber Transmitted player
	 */
	public void effect(int bomber){

	}


}
